//
//  CCBaseViewController.m
//  CCLoveBee
//
//  Created by 陈科 on 2017/2/18.
//  Copyright © 2017年 CK. All rights reserved.
//

#import "CCBaseViewController.h"

@interface CCBaseViewController ()

@end

@implementation CCBaseViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
    [self addleftButtonItem];
    [self addRightButtonItem];
    
}



-(void)addleftButtonItem{
    
    UIButton *leftBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 40, 40)];
    [leftBtn setImage:[UIImage imageNamed:@"icon_black_scancode"] forState:UIControlStateNormal];
    [leftBtn setTitle:@"扫一扫" forState:UIControlStateNormal];
    
    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:leftBtn];
    
}

-(void)addRightButtonItem{
    UIButton *rightBtn = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 40, 40)];
    [rightBtn setImage:[UIImage imageNamed:@"icon_search"] forState:UIControlStateNormal];
    [rightBtn setTitle:@"搜一搜" forState:UIControlStateNormal];
    
    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:rightBtn];
}










@end
